Color digital imaging devices such as color digital cameras have arrays of sensors that detect light. For example, the sensor arrays may comprise arrays of charge-coupled devices (CCDs), CMOS light sensors, active pixel sensors (APS) or the like. Different sensors are sensitive to light in different spectral regions. Most typically each pixel of a sensor array has sub-pixels that are respectively sensitive to red, green and blue light. During an exposure, each sub-pixel provides an output that is related to the amount of light captured by the sub-pixel. The output from each sub-pixel may be read out from the sensor array and represented as a number. These numbers may be called pixel values. For example, some cameras represent the output of each sub-pixel as an 8-bit number which can have values in the range of 0 to 255.
If the amount of light captured by a sub-pixel of a sensor array exceeds a saturation threshold then the sub-pixel becomes saturated. In this context, “saturation” means that an increase in the intensity of light at the sub pixel does not cause an increase in the pixel value produced by the sub-pixel. For example, where a sub-pixel output is represented as an 8-bit value, light intensity at the saturation threshold may produce a pixel value of 255. If the light intensity is increased above the saturation threshold then the sub-pixel will still produce a pixel value of 255. Saturation may occur as a result of physical properties of sub-pixels of a sensor array, the way in which the output of sub-pixels is encoded as numbers, or some combination thereof.
The hue (color) of a pixel in a digital image is a result of the balance between pixel values in different color channels (e.g. of the relative amounts of red, green and blue detected for the pixel). Hue shifts are one consequence of saturation of one or more color channels. Such hue shifts can very significantly alter the appearance of an image.
Consider the example case where the relative values in the red, green and blue channels are in the ratio R:G:B=1:5:1. Such a pixel will have a green hue. If the pixel is moderately lit then the pixel values for that pixel might be, for example 22:110:22. As the illumination of the pixel becomes more intense the pixel values will increase. When the green channel just saturates the pixel values may be 51:255:51. At this point the hue of the pixel has not changed since the ratio 51:255:51 is the same as 1:5:1. If the intensity is increased further the green channel value remains at 255, its saturated value, and cannot increase any more. Values in the non-saturated red and blue channels can still increase. For some greater intensity, the pixel values may be 111:255:111. Now there has been a hue shift because 111:255:111 is no longer in the ratio 1:5:1. If the intensity of light is increased further then all color channels for the pixel may saturate (e.g. have values 255:255:255) in which case the hue of the pixel, which should be a green hue, has been recorded as being white.
There is a need for ways to process image data to improve the appearance of images having pixels or regions in which one or more color channels are saturated.